package com.itheima.demo;

import com.itheima.domain.User;
import org.junit.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class Demo01 {

    @Test
    public void test() {
        ApplicationContext ac = new ClassPathXmlApplicationContext("spring.xml");
        User user = ac.getBean(User.class);
//        User user = ac.getBean("u",User.class);

        System.out.println(user);


    }
}
